package org.jeecg.modules.order.mapper;

import java.util.List;

import com.baomidou.mybatisplus.core.metadata.IPage;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.jeecg.modules.message.entity.SysMessageTemplate;
import org.jeecg.modules.order.controller.OrderQuery;
import org.jeecg.modules.order.entity.Order;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;

/**
 * @Description: 订单
 * @Author: jeecg-boot
 * @Date:   2019-10-06
 * @Version: V1.0
 */
public interface OrderMapper extends BaseMapper<Order> {
    @Select("SELECT * FROM T_ORDER WHERE POS_TRADE_NO = #{payOrderNo}")
    List<Order> findOrderByPayOrderNo(String payOrderNo);

    @Select("SELECT * FROM T_ORDER WHERE ORDER_NO = #{orderNo}")
    List<Order> findOrderByOrderNo(String orderNo);

    public List<Order> page(IPage<Order> page, @Param("orderQuery") OrderQuery orderQuery);
}
